﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Fundamental.Method
{
    internal partial class Partial
    {
        private string m_name;

        partial void OnNameChanged(string name);

        public string Name
        {
            get { return m_name; }
            set 
            {
                OnNameChanged(value);
                m_name = value;
            }
        }
    }

    internal partial class Partial
    {
        partial void OnNameChanged(string name)
        {
            Console.WriteLine(string.Format("New name is: {0}",name));
        }
    }
}
